package com.hl.shifangzhiyu.web;

import com.hl.shifangzhiyu.pojo.reply;
import com.hl.shifangzhiyu.service.Impl.dafuServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/dafu")
public class dafuController {
    @Autowired
    private dafuServiceImpl dafuService;
    @RequestMapping("/save")
    public int save(@RequestBody reply reply){
        return dafuService.save(reply);
    }
    @RequestMapping("/selectAll")
    public List<reply> selectAll(){
        return dafuService.selectAll();
    }
}
